package com.foreknow.demo9Exercise4;

public class Test {

    public static void main(String[] args) {
        Manager emp1 = new Manager();
        emp1.setSalary(8000);
        double salary1 = emp1.getSalary();
        emp1.setYuE(0);

        Clerk emp2 = new Clerk();
        emp2.setSalary(6000);
        double salary2 = emp2.getSalary();
        emp2.setYuE(0);

        System.out.println("=== 初期工资 ===");
        System.out.println("小明的薪资：" + salary1 + " | 银行卡余额：" + emp1.getYuE());
        System.out.println("小亮的薪资：" + salary2 + " | 银行卡余额：" + emp2.getYuE());

        for (int i =1;i<=3;i++) {
            double yuE1 = emp1.yuE();
            yuE1 *= i;
            double yuE2 = emp2.yuE();
            yuE2 *= i;
            System.out.println("=== 第"+i+"个月 ===");
            System.out.println("小明的薪资：" + salary1 + " | 银行卡余额：" + yuE1);
            System.out.println("小亮的薪资：" + salary2 + " | 银行卡余额：" + yuE2);
        }

    }

}
